package Lab01;
/**
 * Created by dell on 2017/10/15.
 */
public class Test13 {
    public static void main(String[] args) {
        int i=1;
        int g,s,b;
        for(i=1;i<1000;i++)
        {
            g=i%10;
            s=(i%100-g)/10;
            b=(i-i%100)/100;
            if (g*g*g+s*s*s+b*b*b==i)
                System.out.println(i);
        }
    }
}
